package com.netflexitysolutions.amazonws.ec2.internal.operations;

import com.amazonaws.ec2.doc._2009_04_04.DeleteSnapshotType;
import com.netflexitysolutions.amazonws.ec2.EC2;

public class DeleteSnapshotOperation extends SingleObjectOperationExecutor<DeleteSnapshotType, Boolean> {

	public DeleteSnapshotOperation(EC2 ec2, String snapshotId) {
		super(ec2, snapshotId);
	}

	@Override
	protected Boolean call(DeleteSnapshotType request) {
		request.setSnapshotId(objectId);
		return getEC2().getService().deleteSnapshot(request).isReturn();
	}

}
